package cn.com.chengmandian.bike.controller;


import cn.com.chengmandian.agent.utils.AuthUtil;
import cn.com.chengmandian.bike.dto.MemberMoneyDto;
import cn.com.chengmandian.bike.model.EbMemberMoney;
import cn.com.chengmandian.bike.service.IEbMemberMoneyService;
import cn.com.chengmandian.core.db.pojo.PageData;
import cn.com.chengmandian.core.web.pojo.AjaxResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 电单车运营-资金流水 前端控制器
 * </p>
 *
 * @author AutoGenerator
 * @since 2021-12-11
 */
@Api(tags = "用户资金流水相关接口")
@RestController
@RequestMapping("/member/money")
public class EbMemberMoneyController {
    @Autowired
    private IEbMemberMoneyService memberMoneyService;

    @ApiOperation("用户资金流水明细")
    @GetMapping("/pages")
    public AjaxResult<PageData<EbMemberMoney>> pages(MemberMoneyDto memberMoneyDto) {
        return AjaxResult.success(PageData.build(memberMoneyService.pages(memberMoneyDto, AuthUtil.getAgentUser())));
    }
}
